from rest_framework import serializers

from .models import ManufacturerModel


class ManufacturerSerializer(serializers.ModelSerializer):
    """制造商信息的序列化器"""

    create_datetime = serializers.DateTimeField(format="%Y-%m-%d %H:%M:%S")
    update_datetime = serializers.DateTimeField(format="%Y-%m-%d %H:%M:%S")

    class Meta:
        model = ManufacturerModel
        fields = '__all__'
